package models;

import java.io.Serializable;
import javax.persistence.*;

import java.util.Date;


/**
 * The persistent class for the loan_history database table.
 * 
 */
@Entity
@Table(name="LOAN_HISTORY")
public class LoanHistory implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@TableGenerator(
            name = "LOAN_HISTORY_SEQ",
            table = "SEQUENCE",
            pkColumnName = "NAME",
            pkColumnValue = "LOAN_HISTORY_SEQ",
            valueColumnName = "CNT",
            initialValue = 10000,
            allocationSize = 1)
    @GeneratedValue(strategy = GenerationType.TABLE, generator = "LOAN_HISTORY_SEQ")
	@Column(unique=true, nullable=false)
	private Integer id;

	@Column(length=100)
	private String action;

	private Integer aid;

	@Column(length=100)
	private String comments;

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name="CREATE_D")
	private Date createD;

	@Column(name="LOAN_APP_ID")
	private Integer loanAppId;

	@Column(name="LOAN_ID")
	private Integer loanId;

	@Column(name="NEW_STATUS")
	private int newStatus;

	@Column(name="OLD_STATUS")
	private int oldStatus;

	private int subject;

	private int type;

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name="UPDATE_D")
	private Date updateD;

	public LoanHistory() {
	}

	public Integer getId() {
		return this.id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getAction() {
		return this.action;
	}

	public void setAction(String action) {
		this.action = action;
	}

	public Integer getAid() {
		return this.aid;
	}

	public void setAid(Integer aid) {
		this.aid = aid;
	}

	public String getComments() {
		return this.comments;
	}

	public void setComments(String comments) {
		this.comments = comments;
	}

	public Date getCreateD() {
		return this.createD;
	}

	public void setCreateD(Date createD) {
		this.createD = createD;
	}

	public Integer getLoanAppId() {
		return this.loanAppId;
	}

	public void setLoanAppId(Integer loanAppId) {
		this.loanAppId = loanAppId;
	}

	public Integer getLoanId() {
		return this.loanId;
	}

	public void setLoanId(Integer loanId) {
		this.loanId = loanId;
	}

	public int getNewStatus() {
		return this.newStatus;
	}

	public void setNewStatus(int newStatus) {
		this.newStatus = newStatus;
	}

	public int getOldStatus() {
		return this.oldStatus;
	}

	public void setOldStatus(int oldStatus) {
		this.oldStatus = oldStatus;
	}

	public int getSubject() {
		return this.subject;
	}

	public void setSubject(int subject) {
		this.subject = subject;
	}

	public int getType() {
		return this.type;
	}

	public void setType(int type) {
		this.type = type;
	}

	public Date getUpdateD() {
		return this.updateD;
	}

	public void setUpdateD(Date updateD) {
		this.updateD = updateD;
	}

}